Local Time

API support for Getting and Setting the local time of the Reader is provided only on FX series readers. The function getLocalTime can be used to get the local time of the reader and the setLocalTime to set the local time of the Reader.

try {

    // Get Reader Local Time  

    String dateTime = rm.getLocalTime();

    System.out.println("Reader’local Time: " + dateTime);

 

    // Set Reader Local Time  

    SYSTEMTIME systemTime = new SYSTEMTIME();

    systemTime.Day = 15;

    systemTime.Month = 7;

    systemTime.Year = 2011;

    systemTime.Hour = 3;

    systemTime.Minute = 15;

    systemTime.Second = 45;

   

    rm.setLocalTime(systemTime);

} catch (OperationFailureException exception) {

    System.out.println("LocalTime failed " + exception.getStatusDescription() + " " + exception.getVendorMessage());

} catch (InvalidUsageException exception){

   

}